#include <stdio.h>
#include <math.h>
#include <assert.h>

#define LLT long long int

#ifndef NDEBUG
    #define DOUT( toprint ) printf( "# " toprint )
    #define DPUT( toput , x ) printf( "# " toput , x )
    #define DLN
#else
    #define DOUT //A blank;
    #define DPUT //Neither do we need this on release state
    #define DLN if(0)
#endif


int main()
{
  DOUT("=======================2007, 1 semester assignment, 1-B=======================\n");
  DOUT("==============================================================================\n");
  DOUT("Please enter a natural number which will be tested on having a square divider:\n");
  DOUT("> ");
  
  LLT n = 0;
  int chk = scanf("%lld", &n);
  DLN assert(("You have entered a single number" , chk == 1));
   
  bool ok = 0 ;//for some reason it doesn't integrate in the for loop
  for(LLT i = 2; i <= sqrt(n); i++) {
     if(  !(n%i) && !( n%(i*i) )  ) {
       ok = 1;
       
       DPUT("The squared divisor we found is %lld\n", (i*i));
       
       break;
     }
  }

	if(ok) printf("YES\n");
	else printf("NO\n");

  DOUT("==============================================================================\n");
  DPUT( "FILE: %s\n", __FILE__ );
  DPUT( "TIME OF COMPILATION: %s\n", __TIME__ );

	return 0;
}
